package com.opencv.controller;

import com.opencv.domain.Order;
import com.opencv.service.OrderService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author qz.wu
 * @date 2021/8/19 14:59
 * @descriptions TODO
 */
@RestController
@Api(tags = "订单")
@RequestMapping("/order/handle")
public class OrderController {

    @Autowired
    private OrderService orderService;

    @ApiOperation("order Api")
    @GetMapping
    public String order(Order order) {
        orderService.orderService(order);
        return "success";
    }

    @ApiOperation("user Api")
    @GetMapping("/user/hello")
    public String user() {
        return "hello user";
    }
}
